package com.hsh.member.service;

import com.hsh.member.base.Result;
import com.hsh.member.entity.Staff;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hsh.member.req.PasswordREQ;
import com.hsh.member.req.StaffREQ;
import org.springframework.boot.autoconfigure.security.reactive.ReactiveSecurityAutoConfiguration;

/**
 * <p>
 * 员工信息表 服务类
 * </p>
 *
 * @author 海上花-www.hsh.com
 * @since 2022-12-01
 */
public interface IStaffService extends IService<Staff> {

    Result search(long page, long size, StaffREQ req);

    Result add(Staff staff);

    Result update(int id,Staff staff);

    /*
        校验原密码是否正确
     */
    Result checkPassword(PasswordREQ req);

    /*
     更新新密码
     */
    Result updatePassWord(PasswordREQ req);

    //登录验证
    Result login(String username, String password);

    /*
    通过令牌获取用户信息
     */
    Result getUserInfo(String token);
}
